Title Banner

Previous Book Contents Book Index Next

Inside Macintosh: QuickTime Components /
Chapter 5 - Sequence Grabber Components / Sequence Grabber Components Reference
Sequence Grabber Component Functions / Working With Channel Characteristics


SGSetChannelMaxFrames

The SGSetChannelMaxFrames function allows you to limit the number of frames
that the sequence grabber will capture from a specified channel. This function works only with channels that have data that is organized into frames, such as video data from a video disc.

pascal ComponentResult SGSetChannelMaxFrames (SGChannel c, 
                                              long frameCount);
c
Specifies the reference that identifies the channel for this operation. You obtain this reference from the SGNewChannel function, described on page 5-29.
frameCount
Specifies the maximum number of frames to capture during the preview or record operation. Set this value to -1 to remove the limit.
DESCRIPTION
You can use the SGSetChannelMaxFrames function in the context of a time-based function to control the number of frames you collect for each unit of time. For example, if you want to collect one frame of data per second, you can create a function that executes once per second. That function should call SGSetChannelMaxFrames to set the maximum frame count to 1. Your application can determine when the frame is captured by calling the SGGetChannelMaxFrames function and detecting when that function returns a value of 0. The SGGetChannelMaxFrames function is described in the next section.

You may use this function only after you have prepared the sequence grabber component for a record operation or during an active record operation. Note that sequence grabber components clear this value when you prepare for a record operation.

SEE ALSO
You can determine whether a channel's data is organized into frames by calling the SGGetChannelInfo function, which is described on page 5-58.

RESULT CODES
paramErr-50Invalid parameter specified
cantDoThatInCurrentMode-9402Request invalid in current mode

Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996




Navigation graphic, see text links

Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help